using System;
using System.Windows.Forms;

namespace TXLooker.WorkItemExtention.UI.QueryManager
{
    internal class DataGridViewQueryColumn : DataGridViewColumn
    {
        // Methods
        public DataGridViewQueryColumn()
            : base(new DataGridViewQueryCell())
        {
        }

        // Properties
        public override DataGridViewCell CellTemplate
        {
            get
            {
                return base.CellTemplate;
            }
            set
            {
                if (!((value == null) || value.GetType().IsAssignableFrom(typeof(DataGridViewQueryCell))))
                {
                    throw new InvalidCastException("Cell must be a Query Cell");
                }
                base.CellTemplate = value;
            }
        }
    }


}